<script>
  import { onMount, onDestroy, beforeUpdate, afterUpdate } from "svelte";
  let message = "Hello World";
  onMount(async () => {
    console.log("onMount");
  });
  onDestroy(() => {
    console.log("onDestroy");
  });
  beforeUpdate(() => {
    console.log("beforeUpdate");
  });
  afterUpdate(() => {
    console.log("afterUpdate");
  });
</script>

<main>
  <h1>Life Cycle</h1>
  <p>{message}</p>
  <input bind:value={message} />
</main>
